/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.restaurant.domain;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author root
 */
@Entity
@Table(name = "exceptionalright")
@XmlRootElement(name = "exceptionalright")
@NamedQueries({
    @NamedQuery(name = "Exceptionalright.findAll", query = "SELECT e FROM Exceptionalright e"),
    @NamedQuery(name = "Exceptionalright.findByExceptionalrightID", query = "SELECT e FROM Exceptionalright e WHERE e.exceptionalrightID = :exceptionalrightID"),
    @NamedQuery(name = "Exceptionalright.findByYear", query = "SELECT e FROM Exceptionalright e WHERE e.year = :year"),
    @NamedQuery(name = "Exceptionalright.findByViewright", query = "SELECT e FROM Exceptionalright e WHERE e.viewright = :viewright"),
    @NamedQuery(name = "Exceptionalright.findByAdditionright", query = "SELECT e FROM Exceptionalright e WHERE e.additionright = :additionright"),
    @NamedQuery(name = "Exceptionalright.findByDeletionright", query = "SELECT e FROM Exceptionalright e WHERE e.deletionright = :deletionright"),
    @NamedQuery(name = "Exceptionalright.findByUpdationright", query = "SELECT e FROM Exceptionalright e WHERE e.updationright = :updationright"),
    @NamedQuery(name = "Exceptionalright.findByShowhide", query = "SELECT e FROM Exceptionalright e WHERE e.showhide = :showhide"),
    @NamedQuery(name = "Exceptionalright.findByCreateddate", query = "SELECT e FROM Exceptionalright e WHERE e.createddate = :createddate"),
    @NamedQuery(name = "Exceptionalright.findByDeleteddate", query = "SELECT e FROM Exceptionalright e WHERE e.deleteddate = :deleteddate"),
    @NamedQuery(name = "Exceptionalright.findByLastupdated", query = "SELECT e FROM Exceptionalright e WHERE e.lastupdated = :lastupdated"),
    @NamedQuery(name = "Exceptionalright.findByIsdeleted", query = "SELECT e FROM Exceptionalright e WHERE e.isdeleted = :isdeleted")})
public class Exceptionalright implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @Column(name = "ExceptionalrightID")
    private Long exceptionalrightID;
    @Column(name = "year")
    @Temporal(TemporalType.DATE)
    private Date year;
    @Column(name = "viewright")
    private Short viewright;
    @Column(name = "additionright")
    private Short additionright;
    @Column(name = "deletionright")
    private Short deletionright;
    @Column(name = "updationright")
    private Short updationright;
    @Column(name = "showhide")
    private Short showhide;
    @Column(name = "createddate")
    @Temporal(TemporalType.DATE)
    private Date createddate;
    @Column(name = "deleteddate")
    @Temporal(TemporalType.DATE)
    private Date deleteddate;
    @Column(name = "lastupdated")
    @Temporal(TemporalType.DATE)
    private Date lastupdated;
    @Column(name = "isdeleted")
    private Boolean isdeleted;

    public Exceptionalright() {
    }

    public Exceptionalright(Long exceptionalrightID) {
        this.exceptionalrightID = exceptionalrightID;
    }

    public Long getExceptionalrightID() {
        return exceptionalrightID;
    }

    public void setExceptionalrightID(Long exceptionalrightID) {
        this.exceptionalrightID = exceptionalrightID;
    }

    public Date getYear() {
        return year;
    }

    public void setYear(Date year) {
        this.year = year;
    }

    public Short getViewright() {
        return viewright;
    }

    public void setViewright(Short viewright) {
        this.viewright = viewright;
    }

    public Short getAdditionright() {
        return additionright;
    }

    public void setAdditionright(Short additionright) {
        this.additionright = additionright;
    }

    public Short getDeletionright() {
        return deletionright;
    }

    public void setDeletionright(Short deletionright) {
        this.deletionright = deletionright;
    }

    public Short getUpdationright() {
        return updationright;
    }

    public void setUpdationright(Short updationright) {
        this.updationright = updationright;
    }

    public Short getShowhide() {
        return showhide;
    }

    public void setShowhide(Short showhide) {
        this.showhide = showhide;
    }

    public Date getCreateddate() {
        return createddate;
    }

    public void setCreateddate(Date createddate) {
        this.createddate = createddate;
    }

    public Date getDeleteddate() {
        return deleteddate;
    }

    public void setDeleteddate(Date deleteddate) {
        this.deleteddate = deleteddate;
    }

    public Date getLastupdated() {
        return lastupdated;
    }

    public void setLastupdated(Date lastupdated) {
        this.lastupdated = lastupdated;
    }

    public Boolean getIsdeleted() {
        return isdeleted;
    }

    public void setIsdeleted(Boolean isdeleted) {
        this.isdeleted = isdeleted;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (exceptionalrightID != null ? exceptionalrightID.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Exceptionalright)) {
            return false;
        }
        Exceptionalright other = (Exceptionalright) object;
        if ((this.exceptionalrightID == null && other.exceptionalrightID != null) || (this.exceptionalrightID != null && !this.exceptionalrightID.equals(other.exceptionalrightID))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.restaurant.domain.Exceptionalright[exceptionalrightID=" + exceptionalrightID + "]";
    }

}
